package com.example.exam.pojo;

import lombok.Data;

/**
 * @author
 * @date 2023/05/27
 */
@Data
public class TestPaperVo {

    /**
     * 手机号或学号
     */
    private String sid;

    /**
     * 题号
     */
    private Integer tid;

    /**
     * 答案
     */
    private String answer;

    /**
     * 成绩
     */
    private int grade;

    public TestPaperVo(TestPaper testPaper) {
        this.sid = testPaper.getSid();
        this.tid = testPaper.getTid();
        this.answer = testPaper.getAnswer();
        this.grade = 0;
    }

    public TestPaperVo(TestPaper testPaper, int grade) {
        this.sid = testPaper.getSid();
        this.tid = testPaper.getTid();
        this.answer = testPaper.getAnswer();
        this.grade = grade;
    }
}
